//
//  OnlineTableCell.m
//  EcmDoctor
//
//  Created by 张进 on 15/7/10.
//  Copyright (c) 2015年 张进. All rights reserved.
//

#import "OnlineTableCell.h"
#import <UIImageView+AFNetworking.h>
#import "NetWorkUtil.h"

@implementation OnlineTableCell

@synthesize descLabel;

- (void)awakeFromNib {
    // Initialization code
    
}

- (void)setOnlineModel:(OnlineModel *)onlineModel {
    [self.headImage setImageWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@%@", [NetWorkUtil getImagesBaseUrl], onlineModel.icon_Url]] placeholderImage:[UIImage imageNamed:@"icon"]];
    self.nameLabel.text = onlineModel.name;
    self.ageLabel.text = [onlineModel.age stringValue];
    self.sex.text = onlineModel.sex;
    self.descLabel.text = onlineModel.content;
    
    if ([onlineModel.isRead isEqualToString:@"1"]) {
        self.isRead.alpha = 0;
    }
    
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
